.container {
  display: flex;
  height: calc(100vh - 64px);
  background: #f9fafb;
}

.sidebar {
  width: 320px;
  background: white;
  border-right: 1px solid #e5e7eb;
  display: flex;
  flex-direction: column;
}

.sidebarHeader {
  padding: 1.5rem;
  border-bottom: 1px solid #e5e7eb;
}

.sidebarTitle {
  font-size: 1.25rem;
  font-weight: 600;
  color: #1f2937;
  margin-bottom: 0.5rem;
}

.searchBox {
  position: relative;
}

.searchInput {
  width: 100%;
  padding: 0.5rem 0.75rem 0.5rem 2.5rem;
  border: 1px solid #d1d5db;
  border-radius: 6px;
  font-size: 0.875rem;
  background: #f9fafb;
}

.searchInput:focus {
  outline: none;
  border-color: #3b82f6;
  background: white;
}

.searchIcon {
  position: absolute;
  left: 0.75rem;
  top: 50%;
  transform: translateY(-50%);
  width: 16px;
  height: 16px;
  color: #6b7280;
}

.topicList {
  flex: 1;
  overflow-y: auto;
  padding: 0.5rem 0;
}

.topicItem {
  display: flex;
  align-items: center;
  padding: 0.75rem 1.5rem;
  cursor: pointer;
  border: none;
  background: none;
  width: 100%;
  text-align: left;
  transition: background-color 0.2s;
}

.topicItem:hover {
  background: #f3f4f6;
}

.topicItem.active {
  background: #eff6ff;
  border-right: 3px solid #3b82f6;
}

.topicIcon {
  width: 40px;
  height: 40px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-right: 0.75rem;
  font-size: 1.25rem;
  font-weight: 600;
  color: white;
}

.topicIconBlue { background: #3b82f6; }
.topicIconGreen { background: #10b981; }
.topicIconPurple { background: #8b5cf6; }
.topicIconOrange { background: #f59e0b; }
.topicIconRed { background: #ef4444; }

.topicContent {
  flex: 1;
  min-width: 0;
}

.topicName {
  font-weight: 500;
  color: #1f2937;
  margin-bottom: 0.25rem;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.topicMeta {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.75rem;
  color: #6b7280;
}

.topicCount {
  background: #f3f4f6;
  padding: 0.125rem 0.375rem;
  border-radius: 12px;
  font-weight: 500;
}

.mainContent {
  flex: 1;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.contentHeader {
  padding: 1.5rem 2rem;
  background: white;
  border-bottom: 1px solid #e5e7eb;
}

.contentTitle {
  font-size: 1.5rem;
  font-weight: 600;
  color: #1f2937;
  margin-bottom: 0.5rem;
}

.contentSubtitle {
  color: #6b7280;
  font-size: 0.875rem;
}

.contentBody {
  flex: 1;
  padding: 1.5rem 2rem;
  overflow-y: auto;
}

.chartSection {
  background: white;
  border-radius: 8px;
  padding: 1.5rem;
  margin-bottom: 1.5rem;
  border: 1px solid #e5e7eb;
}

.chartHeader {
  display: flex;
  align-items: center;
  justify-content: between;
  margin-bottom: 1rem;
}

.chartTitle {
  font-size: 1.125rem;
  font-weight: 600;
  color: #1f2937;
}

.chartContainer {
  height: 300px;
  background: #f9fafb;
  border-radius: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #6b7280;
  font-size: 0.875rem;
  border: 2px dashed #d1d5db;
}

.tableSection {
  background: white;
  border-radius: 8px;
  border: 1px solid #e5e7eb;
  overflow: hidden;
}

.tableHeader {
  padding: 1.5rem;
  border-bottom: 1px solid #e5e7eb;
}

.tableTitle {
  font-size: 1.125rem;
  font-weight: 600;
  color: #1f2937;
}

.table {
  width: 100%;
  border-collapse: collapse;
}

.table th {
  background: #f9fafb;
  padding: 0.75rem 1.5rem;
  text-align: left;
  font-weight: 500;
  color: #374151;
  font-size: 0.875rem;
  border-bottom: 1px solid #e5e7eb;
}

.table td {
  padding: 0.75rem 1.5rem;
  border-bottom: 1px solid #f3f4f6;
  color: #1f2937;
  font-size: 0.875rem;
}

.table tr:last-child td {
  border-bottom: none;
}

.table tr:hover {
  background: #f9fafb;
}

.statusBadge {
  display: inline-flex;
  align-items: center;
  padding: 0.25rem 0.5rem;
  border-radius: 12px;
  font-size: 0.75rem;
  font-weight: 500;
}

.statusActive {
  background: #dcfce7;
  color: #166534;
}

.statusInactive {
  background: #fef2f2;
  color: #991b1b;
}

.statusPending {
  background: #fef3c7;
  color: #92400e;
}

.emptyState {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  height: 100%;
  color: #6b7280;
  text-align: center;
}

.emptyIcon {
  width: 64px;
  height: 64px;
  margin-bottom: 1rem;
  opacity: 0.5;
}

.emptyTitle {
  font-size: 1.125rem;
  font-weight: 500;
  margin-bottom: 0.5rem;
}

.emptyDescription {
  font-size: 0.875rem;
}

/* 响应式设计 */
@media (max-width: 1200px) {
  .container {
    flex-direction: column;
    height: auto;
    min-height: calc(100vh - 64px);
  }
  
  .sidebar {
    width: 100%;
    max-height: 300px;
    border-right: none;
    border-bottom: 1px solid #e5e7eb;
  }
  
  .topicList {
    max-height: 200px;
  }
}

@media (max-width: 768px) {
  .sidebar {
    max-height: 250px;
  }
  
  .sidebarHeader {
    padding: 1rem;
  }
  
  .sidebarTitle {
    font-size: 1.1rem;
  }
  
  .topicItem {
    padding: 0.5rem 1rem;
  }
  
  .topicIcon {
    width: 35px;
    height: 35px;
    font-size: 1.1rem;
    margin-right: 0.5rem;
  }
  
  .topicName {
    font-size: 0.9rem;
  }
  
  .topicMeta {
    font-size: 0.7rem;
    gap: 0.25rem;
  }
  
  .contentHeader {
    padding: 1rem 1.5rem;
  }
  
  .contentTitle {
    font-size: 1.3rem;
  }
  
  .contentSubtitle {
    font-size: 0.8rem;
  }
  
  .contentBody {
    padding: 1rem 1.5rem;
  }
  
  .topicList {
    max-height: 180px;
  }
}

@media (max-width: 480px) {
  .sidebarHeader {
    padding: 0.75rem;
  }
  
  .sidebarTitle {
    font-size: 1rem;
    margin-bottom: 0.75rem;
  }
  
  .searchInput {
    padding: 0.375rem 0.5rem 0.375rem 2rem;
    font-size: 0.8rem;
  }
  
  .searchIcon {
    width: 14px;
    height: 14px;
    left: 0.5rem;
  }
  
  .topicItem {
    padding: 0.375rem 0.75rem;
  }
  
  .topicIcon {
    width: 30px;
    height: 30px;
    font-size: 1rem;
    margin-right: 0.375rem;
  }
  
  .topicName {
    font-size: 0.8rem;
  }
  
  .topicMeta {
    font-size: 0.65rem;
  }
  
  .contentHeader {
    padding: 0.75rem 1rem;
  }
  
  .contentTitle {
    font-size: 1.2rem;
  }
  
  .contentSubtitle {
    font-size: 0.75rem;
  }
  
  .contentBody {
    padding: 0.75rem 1rem;
  }
  
  .topicList {
    max-height: 150px;
  }
  
  .emptyIcon {
    width: 48px;
    height: 48px;
  }
  
  .emptyTitle {
    font-size: 1rem;
  }
  
  .emptyDescription {
    font-size: 0.8rem;
  }
}
